Skip to content

fix(build): make react-ui and browser-bundle build scripts cross-plat…#604

Merged
abhithesys merged 3 commits into
thesysdev:mainfrom
shogun444:fix/cross-platform-build-react-ui-browser-bundle
Jun 9, 2026
Merged

fix(build): make react-ui and browser-bundle build scripts cross-plat…#604
abhithesys merged 3 commits into
thesysdev:mainfrom
shogun444:fix/cross-platform-build-react-ui-browser-bundle

Conversation

@shogun444

Copy link
Copy Markdown
Contributor

What

Fixes #603 by replacing Unix-specific build commands with cross-platform Node.js helper scripts in @openuidev/react-ui and @openuidev/browser-bundle.

On Windows, builds fail with:

'rm' is not recognized as an internal or external command,
operable program or batch file.

Changes

Replaced rm -rf and mkdir -p usage with Node.js filesystem APIs while preserving the existing build behavior.

Test Plan

  • Not applicable (explain why)
  • Verified locally

Validated on Windows 11 using PowerShell.

@openuidev/react-ui now builds successfully.

@openuidev/browser-bundle progresses past the shell-command failure and reaches the bundling stage. Validation exposed a separate module resolution issue:

Could not resolve "./openuiLibrary.tsx"
Could not resolve "./library.ts"
Could not resolve "./Renderer.tsx"

These errors appear unrelated to the Windows compatibility issue addressed in this PR.

Checklist

  • I linked a related issue, if applicable
  • I updated docs/README when needed
  • I considered backwards compatibility

@vishxrad vishxrad self-requested a review June 4, 2026 20:31

@abhithesys abhithesys left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes look good. Can you update the PR to use rimraf pkg instead?
Its a well known pkg to solve this particular issue, we shouldn't need to write this script in every pkg that exists in Openui.

@shogun444

Copy link
Copy Markdown
Contributor Author

Updated the PR to use rimraf and removed the custom cleanup scripts. Re-tested on Windows and the original build-script issue is resolved. Thanks!

@abhithesys abhithesys left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LG. :shipit:

@abhithesys abhithesys merged commit ed58b37 into thesysdev:main Jun 9, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Windows build fails in react-ui and browser-bundle due to Unix-specific build scripts

2 participants